import 'package:finance_app/generated/json/base/json_field.dart';

class SettingDataImportOpeningBalancesEntity {
  @JSONField(name: "Type*")
  String typeStar;
  @JSONField(name: "Header* (Parent AC)")
  String headerParentAc;
  @JSONField(name: "Account Name*")
  String accountName;
  @JSONField(name: "Currency*")
  String currencyStar;
  @JSONField(name: "Opening Bal (Foreign Currency)")
  String openingBalForeignCurrency;
  @JSONField(name: "Opening Bal (Default Currency)")
  String openingBalDefaultCurrency;
  int line;

  SettingDataImportOpeningBalancesEntity(
      {this.typeStar,
      this.headerParentAc,
      this.accountName,
      this.currencyStar,
      this.openingBalForeignCurrency,
      this.line,
      this.openingBalDefaultCurrency});

  factory SettingDataImportOpeningBalancesEntity.fromJson(
      Map<String, dynamic> json) {
    return SettingDataImportOpeningBalancesEntity(
      typeStar: json['Type*'],
      headerParentAc: json['Header* (Parent AC)'],
      accountName: json['Account Name*'],
      currencyStar: json['Currency*'],
      openingBalForeignCurrency: json['Opening Bal (Foreign Currency)'],
      line: json['line'],
      openingBalDefaultCurrency: json['Opening Bal (Default Currency)'],
    );
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['Type*'] = this.typeStar;
    data['Header* (Parent AC)'] = this.headerParentAc;
    data['Account Name*'] = this.accountName;
    data['Currency*'] = this.currencyStar;
    data['Opening Bal (Foreign Currency)'] = this.openingBalForeignCurrency;
    data['line'] = this.line;
    data['Opening Bal (Default Currency)'] = this.openingBalDefaultCurrency;
    return data;
  }
}
